package com.example.educationblockchain.util;

//常量工具类

public class BlockConstant {
    // 测试1
    public final static int P2P_TEST1 = -1;

    // 测试2
    public final static int P2P_TEST2 = -2;

    //节点链接
    public final static int PEER_CONNECT = 0;

    // 服务端接收客户端请求最新区块的请求
    public final static int QUERY_LATEST_BLOCK = 1;

    // 客户端接收服务端发送的最新区块
    public final static int RESPONSE_LATEST_BLOCK = 2;

    // 服务端接收客户端请求指定区块的请求
    public final static int QUERY_BLOCK = 3;

    // 客户端接收服务端发送的指定区块
    public final static int RESPONSE_BLOCK = 4;

    // 服务端接收客户端sse请求指定区块的请求
    public final static int Sse_QUERY_BLOCK = 5;

    // 客户端sse接收服务端发送的指定区块
    public final static int Sse_RESPONSE_BLOCK = 6;

    // 客户端接收服务端发送的错误区块信息
    public final static int ERROR_BLOCK = 7;
}
